package com.fsnbigdata.service.api;
import com.fsnbigdata.domain.AnimalConservation;
import com.fsnbigdata.domain.Organism;
import com.fsnbigdata.domain.ZhEcologyNav;
import com.fsnbigdata.domain.dto.NamingPair2;
import com.querydsl.core.types.Predicate;
import org.springframework.roo.addon.layers.service.annotations.RooService;
import com.fsnbigdata.domain.AnimalConservationLocation;
import io.springlets.data.domain.GlobalSearch;
import io.springlets.format.EntityResolver;
import java.util.List;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

/**
 * = AnimalConservationService
 *
 * TODO Auto-generated class documentation
 *
 */
@RooService(entity = AnimalConservation.class)
public interface AnimalConservationService extends EntityResolver<AnimalConservation, Long> {

    /**
     * TODO Auto-generated method documentation
     *
     * @param id
     * @return AnimalConservation
     */
    public abstract AnimalConservation findOne(Long id);

    /**
     * TODO Auto-generated method documentation
     *
     * @param animalConservation
     */
    public abstract void delete(AnimalConservation animalConservation);

    /**
     * TODO Auto-generated method documentation
     *
     * @param entities
     * @return List
     */
    public abstract List<AnimalConservation> save(Iterable<AnimalConservation> entities);

    /**
     * TODO Auto-generated method documentation
     *
     * @param ids
     */
    public abstract void delete(Iterable<Long> ids);

    /**
     * TODO Auto-generated method documentation
     *
     * @param entity
     * @return AnimalConservation
     */
    public abstract AnimalConservation save(AnimalConservation entity);

    /**
     * TODO Auto-generated method documentation
     *
     * @param id
     * @return AnimalConservation
     */
    public abstract AnimalConservation findOneForUpdate(Long id);

    /**
     *
     * @param predicate
     * @param pageable
     * @return
     */
    public abstract Page<AnimalConservation> search(Predicate predicate, Pageable pageable);

    /**
     * TODO Auto-generated method documentation
     *
     * @param ids
     * @return List
     */
    public abstract List<AnimalConservation> findAll(Iterable<Long> ids);

    /**
     * TODO Auto-generated method documentation
     *
     * @return List
     */
    public abstract List<AnimalConservation> findAll();

    /**
     * TODO Auto-generated method documentation
     *
     * @return Long
     */
    public abstract long count();

    /**
     * TODO Auto-generated method documentation
     *
     * @param globalSearch
     * @param pageable
     * @return Page
     */
    public abstract Page<AnimalConservation> findAll(GlobalSearch globalSearch, Pageable pageable);


    /**
     * TODO Auto-generated method documentation
     *
     * @param globalSearch
     * @param pageable
     * @return Page
     */
    public abstract Page<AnimalConservation> findAll(GlobalSearch globalSearch, Pageable pageable, String creator);

    /**
     * TODO Auto-generated method documentation
     *
     * @param ids
     * @param globalSearch
     * @param pageable
     * @return Page
     */
    public abstract Page<AnimalConservation> findAllByIdsIn(List<Long> ids, GlobalSearch globalSearch, Pageable pageable);

    /**
     * TODO Auto-generated method documentation
     *
     * @param animalConservation
     * @param locationToAdd
     * @return AnimalConservation
     */
    public abstract AnimalConservation addToLocation(AnimalConservation animalConservation, Iterable<AnimalConservationLocation> locationToAdd);

    /**
     * TODO Auto-generated method documentation
     *
     * @param animalConservation
     * @param locationToRemove
     * @return AnimalConservation
     */
    public abstract AnimalConservation removeFromLocation(AnimalConservation animalConservation, Iterable<Long> locationToRemove);

    List<NamingPair2> findAllByInitial(String initial);

    List findByType();

    List getPageList(String condition, String preserveLocation, Pageable pageable);

    List queryByAlphabet(String s);

    List hit();
}
